public class Pet {
    private  String type;
    private  int age;
    private boolean vaccinum;
    public void setType(String type){
        this.type = type;
    }
    public void setAge(int age){
        this.age = age;
    }

    public String getType() {
        return type;
    }

    public int getAge() {
        return age;
    }


    public boolean setVaccinum(boolean vaccinum) {
        this.vaccinum = vaccinum;
        return this.vaccinum;
    }

    public static void main(String[] args){
        Pet pet1 = new Pet();
        pet1.setType("Dog");
        pet1.setAge(3);
        pet1.setVaccinum(true);

        Pet pet2 = new Pet();
        pet2.setType("Cat");
        pet2.setAge(2);
        pet2.setVaccinum(false);
        System.out.println("种类是"+pet1.getType()+" 年龄为"+ pet1.getAge()+" 接种疫苗情况为："+pet1.setVaccinum(true));
        System.out.println("种类是"+pet2.getType()+" 年龄为"+ pet2.getAge()+" 接种疫苗情况为："+pet2.setVaccinum(true));
    }
}

